package com.xingchen.loveparttimejob.model.pojo;

import java.sql.Date;
import java.util.HashMap;
import java.util.Map;

/**
 * @author lwj
 * @date 2024-12-03
 * @vesion 1.0.0
 */
public class JobBenefits {
    /**
     * 工作福利编号
     */
    private int jbId;
    /**
     * 职位编号（外键）
     */
    private int jiId;
    /**
     * 提成描述
     */
    private String bonus;
    /**
     * 福利描述
     */
    private String benefits;
    /**
     * 创建时间
     */
    private Date createTime;
    /**
     * 是否删除
     */
    private int state;

    // 构造方法
    public JobBenefits() {}
    public JobBenefits(int jbId, int jiId, String bonus, String benefits, Date createTime, int state) {
        this.jbId = jbId;
        this.jiId = jiId;
        this.bonus = bonus;
        this.benefits = benefits;
        this.createTime = createTime;
        this.state = state;
    }

    /**
     * 反射中使用到
     * @return
     */
    public Map<String,String> getMapping(){
        Map<String,String> map = new HashMap<>();
        map.put("jbId","jb_id");
        map.put("jiId","ji_id");
        map.put("bonus","bonus");
        map.put("benefits","benefits");
        map.put("createTime","create_time");
        map.put("state","state");
        return map;
    }

    // 属性
    public int getJbId() {
        return jbId;
    }

    public void setJbId(int jbId) {
        this.jbId = jbId;
    }

    public int getJiId() {
        return jiId;
    }

    public void setJiId(int jiId) {
        this.jiId = jiId;
    }

    public String getBonus() {
        return bonus;
    }

    public void setBonus(String bonus) {
        this.bonus = bonus;
    }

    public String getBenefits() {
        return benefits;
    }

    public void setBenefits(String benefits) {
        this.benefits = benefits;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public int getState() {
        return state;
    }

    public void setState(int state) {
        this.state = state;
    }

    /**
     * 打印工作福利表
     * @return
     */
    @Override
    public String toString() {
        return "JobBenefits{" +
                "jbId=" + jbId +
                ", jiId=" + jiId +
                ", bonus='" + bonus + '\'' +
                ", benefits='" + benefits + '\'' +
                ", createTime=" + createTime +
                ", state=" + state +
                '}';
    }
}
